package com.wcx.application.service.Impl;

import com.wcx.application.domian.BossBean;
import com.wcx.application.domian.CompanyBean;
import com.wcx.application.mapper.BossMapper;
import com.wcx.application.mapper.CompanyMapper;
import com.wcx.application.service.BossService;
import com.wcx.application.service.CompanyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CompanyServiceImpl implements CompanyService {
    @Autowired
    CompanyMapper companyMapper;

    @Override
    public List<CompanyBean> getList() {
        return companyMapper.getList();
    }

    @Override
    public int update(CompanyBean companyBean) {
        return companyMapper.update(companyBean);
    }

    @Override
    public int delete(int id) {
        return companyMapper.delete(id);
    }

    @Override
    public int updateAvatarById(String originalFilename, int id) {
        return companyMapper.updateAvatarById(originalFilename,id);
    }

    @Override
    public int create(CompanyBean companyBean) {
        return companyMapper.create(companyBean);
    }

    @Override
    public List<CompanyBean> searchList(CompanyBean companyBean) {
        return companyMapper.searchList(companyBean);
    }

    @Override
    public int updateAvatarByUserName(String originalFilename, String name) {
        return companyMapper.updateAvatarByUserName(originalFilename,name);
    }


}
